<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>web技术基础实验V4.1</title>
    <link rel="icon" href="imgs/圣诞麋鹿.png">
    <link rel="stylesheet" href="css/index.css">
    <script src="./js/utils/utils.js"></script>
</head>
<body style="height: 720px; ">
    <h2 id="top" align="center">2023-2024学年课程情况</h2>
    <div  class="menu">
        <div class="alive">
            <a href="kcjs.html" target="mainframe">课程简介</a>
            <a href="kebi.html" target="mainframe">课表</a>
            <a href="jiaocai.html" target="mainframe">教材</a>
            <a href="beiwang.html" target="mainframe">备忘录</a>
        </div>
        <div id="timeer" style="color: red;"></div>
    </div>
    <iframe  name="mainframe" src="kcjs.html" width="100%" height="100%" frameborder="1"></iframe>
    <div class="bottom">&copy;闽江学院 计算机和大数据学院&trade;软件工程 <br>联系人: 江炳坤 学号：3232508217</div>
    <script>
        var mobile=false;
        var device=navigator.userAgent;
        if((device.indexOf("iphone")>0)||(device.indexOf("Android")>0)) mobile=true
        if(mobile) setInterval(getnowTime,900);
        else setInterval(getnewTime,900);
        function getnewTime(){
            var m=new Date();
            var formatestring=m.format("yyyy-MM-dd hh:mm:ss");
            document.getElementById("timeer").innerHTML = formatestring ;
            var iframeHeight=document.documentElement.clientHeight-document.getElementsByClassName("bottom")[0].clientHeight-(document.getElementById("top").clientHeight+document.getElementsByClassName("menu")[0].clientHeight+document.getElementsByClassName("bottom")[0].clientHeight);
            var iframeElement=document.getElementsByName("mainframe")[0];
            iframeElement.style.height=iframeHeight+'px';
        }
        function getnowTime(){
            var m=new Date();
            var formatestring=m.format("hh:mm:ss");
            document.getElementById("timeer").innerHTML = formatestring ;
        }
    </script>
</body>
</html>